#!/bin/sh

###############################################

#
# 检查入参
#
#---------------------------------------------
if [ $# -lt 1 ]
then
    echo "Error! Not Enough Params."
    echo "Usage : sh app -a app_need_to_check [-b build_js] [-d deploy_web]"
    exit 1;
fi

#
# 定义变量
#
#---------------------------------------------
#app=0;         	# app_need_to_check
#build=0;         	# build_js
#deploy=0;          # deploy_web
#---------------------------------------------

while getopts "t:" opt
do 
    case $opt in
        t) #set option "t"
            test=$OPTARG
            ;;
        *)
            echo "-$opt not recognized"
            ;;
    esac
done

echo "test: " ${test}

echo "common-info begin..."

/home/working/mvnsrv.sh -a common-info -s assembly -d deploy -t ${test} -g dev

echo "common-info end."

#read -p 'continue?[y/n]' isContinue
#echo ${isContinue}

echo ""
echo ""
echo ""

echo "webservice begin..."

/home/working/mvnraw.sh -a webservice -d deploy -t ${test} -b all  -g dev


echo "webservice end."

